namespace IAM.Interface.Common.Providers
{
    using IAM.Interface.Common;
    using IAM.Interface.Common.Encrypt;
    using System;

    public abstract class IProvider
    {
        protected IAM.Interface.Common.Encrypt.EncryptDecrypt _endecrypt = null;
        protected string _sendstring = "";
        protected string _sign = "";
        protected string _url = "";
        protected string _xml = "";

        protected IProvider()
        {
        }

        public virtual string GetResponseStr()
        {
            return "";
        }

        protected virtual void SetWholeSendStr()
        {
            string wholexml = ("xml=" + EnDeCoding.Encode(this.XML)) + "&sign=" + EnDeCoding.Encode(this.Sign);
            this._sendstring = wholexml;
        }

        public virtual IAM.Interface.Common.Encrypt.EncryptDecrypt EncryptDecrypt
        {
            get
            {
                return this._endecrypt;
            }
        }

        public virtual string SendStr
        {
            get
            {
                return this._sendstring;
            }
        }

        public virtual string Sign
        {
            get
            {
                return this._sign;
            }
            set
            {
                this._sign = value;
            }
        }

        public virtual string URL
        {
            get
            {
                return this._url;
            }
            set
            {
                this._url = value;
            }
        }

        public virtual string XML
        {
            get
            {
                return this._xml;
            }
            set
            {
                this._xml = value;
            }
        }
    }
}
